package com.cf.wim.config;

import lombok.extern.slf4j.Slf4j;
import org.springframework.context.annotation.Configuration;
import org.springframework.util.ResourceUtils;
import org.springframework.web.servlet.config.annotation.ResourceHandlerRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter;

/**
 * boot-web-LongToStringConvert
 *
 * @author <a href="2428922347@qq.com">Zhu mingming</a>
 * @info
 * @since 2018/7/13 下午 01:54
 */
@Slf4j
@Configuration
public class ImBackStaticConfig extends WebMvcConfigurerAdapter {

    @Override
    public void addResourceHandlers(ResourceHandlerRegistry registry) {
        registry.addResourceHandler("/b-chat/**").addResourceLocations(ResourceUtils.CLASSPATH_URL_PREFIX + "/im-admin-static/b-chat/");
        registry.addResourceHandler("/b-chat.html").addResourceLocations(ResourceUtils.CLASSPATH_URL_PREFIX + "/im-admin-static/b-chat.html");
        super.addResourceHandlers(registry);
    }

}
